package com.design.blog.controller;

import com.design.blog.model.R;
import com.design.blog.service.impl.CategoryServiceImpl;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;

/**
 * @author hxg
 * @version 1.0
 * @date 2022/2/28 23:15
 */
@RestController
@RequestMapping("/category")
public class CategoryController {
    @Resource
    private CategoryServiceImpl categoryServiceImpl;

    @PostMapping("/getCategorys")
    public R getCategorys(){
        return R.success(categoryServiceImpl.getCategorys());
    }

   /* @GetMapping("/getCategoryArticles/{id}")
    public R getCategoryArticles(@PathVariable("id") Long id){
        return R.success(categoryServiceImpl.getCategoryArticles(id));
    }*/
}
